import { createApp } from 'vue'
import './style.scss'
import App from './App.vue'

//引入element
import ElementPlus from 'element-plus'
import 'element-plus/dist/index.css'

//引入封装的axios
// import axios from 'axios';
// 引入路由
//创建Hash路由 路由组件
import { createWebHashHistory,createRouter } from "vue-router";
const router = createRouter({
    routes:[{
        path:'/',
        component:()=>import('./components/login.vue'),
        name:'Login'
    },{
        path:'/model',
        component:()=>import('./components/model.vue'),
        name:'Model'
    },
    {
        path:'/content',
        component:()=>import('./components/content.vue'),
        name:'Content',
        children:[
            {
                path:'',
                component:()=>import('./components/index.vue'),
                name:'Index'
            },
            {
                path:'/content/indexHD',
                component:()=>import('./components/indexHD.vue'),
                name:'IndexHD',
            },
        ],
    },
],
    history:createWebHashHistory()//历史路由模式
    
})
const app = createApp(App);
app.use(router);
app.use(ElementPlus);
app.mount('#app');

 
